﻿@* Binding context: ArtistForAlbumEditViewModel *@

<tr>
	<td>
		<div data-bind="with: artist">
			<a data-bind="text: $parent.name, attr: { href: vdb.utils.EntryUrlMapper.details('Artist', id) }, artistToolTip: id" href="#"></a>
			<br />
			<span data-bind="text: additionalNames" class="extraInfo"></span>
		</div>
		<div data-bind="ifnot: artist">
			<span data-bind="text: name"></span>
		</div>
		@if (VocaDb.Model.Utils.AppConfig.AllowCustomArtistName) {
			<a href="#" class="textLink editLink" data-bind="click: $parent.customizeName">@ViewRes.Album.ArtistForAlbumEditRowStrings.Customize</a>		
		}
	</td>
	<td>
		<label class="checkbox inline">
			<input type="checkbox" data-bind="checked: isSupport" />
			@ViewRes.Album.ArtistForAlbumEditRowStrings.Support
		</label>
	</td>
	<td>
		<div data-bind="foreach: rolesArray">
			<div data-bind="ifnot: $data == 'Default'">
				<span data-bind="text: $root.translateArtistRole($data)"></span>
				<br />				
			</div>
		</div>

		<div data-bind="visible: isCustomizable">
			<a href="#" class="artistRolesEdit textLink editLink" data-bind="click: $parent.editArtistRoles">@ViewRes.Album.ArtistForAlbumEditRowStrings.Customize</a>
		</div>
	</td>
	<td>
		<a data-bind="click: $root.removeArtist" href="#" class="textLink removeLink">@ViewRes.SharedStrings.Remove</a>
	</td>
</tr>